﻿using System;
using System.Collections.Generic;
using System.Text;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using Chaliy.DbPro.Generators.TextAuthoring.Configuration;

namespace Chaliy.DbPro.Generators.Tests.TextAuthoring.Confgiration
{
	[TestClass]
	public class ParagraphConfigurationTests
	{
		[TestMethod]
		[DeploymentItem(DeploymentConstants.GeneratorsDll)]
		public void TestMinLengthConfiguration()
		{
			ParagraphConfiguration configuration = ParagraphConfigurationTests.GetEtalonData();
			Assert.AreEqual(5, configuration.MinLength);
		}

		[TestMethod]
		[DeploymentItem(DeploymentConstants.GeneratorsDll)]
		public void TestMaxLengthConfiguration()
		{
			ParagraphConfiguration configuration = ParagraphConfigurationTests.GetEtalonData();
			Assert.AreEqual(8, configuration.MaxLength);
		}

		private static ParagraphConfiguration GetEtalonData()
		{
			return DataUtlities.CreateEtalonData().Paragraph;
		}
	}
}
